<%--
  Created by IntelliJ IDEA.
  User: Snakewood
  Date: 2020/12/25
  Time: 9:38
  To change this template use File | Settings | File Templates.
--%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8"%>

<div style="text-align: center;">
    <h2><a href="index.jsp" style="text-decoration: none">零食之家</a></h2>

</div>
<div style="text-align: right;">
<span style="text-align: right;margin-right: 300px;">&nbsp;&nbsp;&nbsp;
            <c:if test="${empty user}">
                <a style="font-size: 12px" href="login.jsp">登录💡</a>&nbsp;
                <a style="font-size: 12px" href="regist.jsp">注册🕸</a>&nbsp;
            </c:if>
                <c:if test="${not empty user}">
                    ${user.username},你好！&nbsp;&nbsp;
                    <a style="font-size: 12px" href="user?op=logout">注销🚪</a>&nbsp;&nbsp;
                </c:if>

            <a style="font-size: 12px" href="cartList.jsp">购物车🛒</a>
</span>
</div>
